home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 4801 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.6 KB

  1. Path: news1.h1.usa.pipeline.com!usenet
  2. From: bjones1@usa.pipeline.com(Bill Jones)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: GadTools Callback question...
  5. Date: 5 Mar 1996 07:59:12 GMT
  6. Organization: Pipeline USA
  7. Message-ID: <4hgs8g$7ui@news1.usa.pipeline.com>
  8. NNTP-Posting-Host: pipe4.h1.usa.pipeline.com
  9. X-PipeUser: bjones1
  10. X-PipeHub: usa.pipeline.com
  11. X-PipeGCOS: (Bill Jones)
  12. X-Newsreader: Pipeline USA v3.4.0
  13.  
  14. I am rather new at doing callback hooks for GadTools but I wanted to give
  15. it a try for the new Phasar program.  I am using the STRING_KIND gadget
  16. which has a StringExtend structure and a pointer to my subroutine in the
  17. EditHook field.  One hook is being used for date entry in the format of
  18. mm/dd/yy where the slashes (/) are automatically processed by the callback
  19. hook.  Another formats money fields the same way a cash register would. 
  20. Both hooks work as expected when data is being entered.  Both need to
  21. inspect data contained within the STRING gadget BEFORE any data is entered.
  22.  Therefore I need to know as soon as someone clicks on the gadget or enters
  23. the gadget via the tab-cycle.   
  24.  
  25. Clicking on the gadget gives an interrupt to my callback hook as expected
  26. and I can correct the data in the gadget before any typing is performed. 
  27. However, when the gadget is activated via the tab key the SGH_CLICK command
  28. is not sent to my hook.  What I need to know is how to get control of the
  29. gadget as soon as it is entered (activated) via the tab key or an
  30. SGA_NEXTACTIVE command.   
  31.  
  32. Thanks for any help in this area.   
  33. -- 
  34. Phasar Amiga Software 
  35. Bill Jones 
  36. bjones1@usa.pipeline.com
  37.